package com.ibeeking.found.file.rest.service.office.documentserver.models.configurations;

import com.ibeeking.found.file.rest.service.office.documentserver.storage.FileStoragePathBuilder;
import lombok.Getter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;
import javax.annotation.Resource;

@Component
@Scope("prototype")
public class Goback {  // the settings for the Open file location menu button and upper right corner button

    @Resource
    private FileStoragePathBuilder storagePathBuilder;


    @Getter
    private String url;  // the absolute URL to the website address which will be opened when clicking the Open file location menu button

    @PostConstruct
    private void init() {
        this.url = storagePathBuilder.getServerUrl(false);
    }
}
